#include <iostream>
#include <map>
#include <list>
#include <ctime>
#include "Object.h"
#include "CView.h"

int main(int argc, char* argv[])
{
    IDrink* lpCoffee = new CCoffee();
    std::cout << lpCoffee->GetDrinkName() << ", " << lpCoffee->GetDrinkCost() << std::endl;

    lpCoffee = new CCream(lpCoffee);
    std::cout << lpCoffee->GetDrinkName() << ", " << lpCoffee->GetDrinkCost() << std::endl;

    IDrink* lpMilkTea = new CMilkTea();
    std::cout << lpMilkTea->GetDrinkName() << ", " << lpMilkTea->GetDrinkCost() << std::endl;

    lpMilkTea = new CPearl(lpMilkTea);
    std::cout << lpMilkTea->GetDrinkName() << ", " << lpMilkTea->GetDrinkCost() << std::endl;

    lpMilkTea = new CCream(lpMilkTea);
    std::cout << lpMilkTea->GetDrinkName() << ", " << lpMilkTea->GetDrinkCost() << std::endl;

    if (lpCoffee)
        delete lpCoffee;

    if (lpMilkTea)
        delete lpMilkTea;

    CWindow WinObj;
    CClient* lpClient = new CClient();

    WinObj.AddControl(lpClient);

    CEdit* lpEdit = new CEdit(lpClient);
    CBorder* lpBorder = new CBorder(lpClient);
    CScrollBars* lpScrollBars = new CScrollBars(lpClient);

    WinObj.AddControl(lpEdit);
    WinObj.AddControl(lpBorder);
    WinObj.AddControl(lpScrollBars);
    WinObj.Draw();

    return 0;
}